﻿using System;
using System.ServiceModel;

namespace SearchFrontEnd
{
    /// <summary>
    /// The definition of the interface exposed by the front end server to the
    /// back end servers. 
    /// </summary>
    [ServiceContract]
    public interface ISearchRegistry
    {
        /// <summary>
        /// Registers a back end server in the registry of the front end server.
        /// </summary>
        /// <param name="address">Back end server's address.</param>
        [OperationContract]
        void AddBackEndServer(Uri address);

        /// <summary>
        /// Removes registration of a back end server in the registry of the 
        /// front end server.
        /// </summary>
        /// <param name="address">Back end server's address.</param>
        [OperationContract]
        void RemoveBackEndServer(Uri address);
    }
}
